package com.leetcode.algorithm.y22.m06;

/**
 * 389. 找不同
 * 
 * https://leetcode.cn/problems/find-the-difference/
 * 
 * @author jie.deng
 *
 */
class Question0039Solution01 {
	
	public char findTheDifference(String s, String t) {
		char ch = 0;
		for (int i = 0; i < s.length(); i++) {
			ch ^= s.charAt(i);
		}
		for (int i = 0; i < t.length(); i++) {
			ch ^= t.charAt(i);
		}
		return ch;
	}
    
}